Memory controller and method capable of using different storing modes to store data units having different data sizes

ABSTRACT

A method applied into a memory controller coupled between a memory device and a host device wherein the memory device supports at least two different storing modes includes: receiving and buffering data transmitted from the host device; using a first storing mode to store a first data unit into the memory device, a size of the first data unit being not larger than a size of a specific storage unit defined in the memory device; and using a second storing mode, different from the first storing mode, to store a second data unit into the memory device, a size of the second data unit being larger than the size of the specific storage unit.

BACKGROUND OF THE INVENTION 1. Field of the Invention

The invention relates to a memory controller storing mechanism, and moreparticularly to a memory controller and corresponding method capable ofdynamically using different storing modes to store different sizes ofdata into a memory device.

2. Description of the Prior Art

Generally speaking, when a conventional memory controller writes orstores data units into a flash memory which supports an MLC(multi-level-cell) storing mode, the conventional memory controllerneeds to read back portion data from the flash memory and then uses theportion data with the data unit to be stored to form/generate evenstorage page data and odd storage page data, and then store the evenstorage page data and odd storage page data into an even storage pageand an odd storage page of the flash memory for one storing operation.This portion data may comprise tail data and/or header data, and theoperation of using the portion data with the data unit to form the pagedata can be regarded as a data complement process. That is, for a singleone storing operation, the conventional memory controller is arranged tostore a data amount of two storage pages into even and odd storage pagesof the flash memory even though the size of data unit transmitted fromhost device and to be stored is smaller than that of one storage page.The performance of storing data is thus degraded.

SUMMARY OF THE INVENTION

Therefore one of the objectives of the invention is to provide a memorycontroller and method to solve the above-mentioned problems.

According to embodiments of the invention, a memory controller coupledbetween a memory device and a host device is disclosed. The memorydevice supports at least two different storing modes. The memorycontroller comprises a buffer circuit and a processing circuit. Thebuffer circuit is configured for receiving and buffering datatransmitted from the host device. The processing circuit is coupled tothe buffer circuit and is configured for: using a first storing mode tostore a first data unit into the memory device, a size of the first dataunit being not larger than a size of a specific storage unit defined inthe memory device; and using a second storing mode, different from thefirst storing mode, to store a second data unit into the memory device,a size of the second data unit being larger than the size of thespecific storage unit.

According to the embodiments, a memory controller coupled between amemory device and a host device is further disclosed. The memory devicesupports at least two different storing modes. The memory controllercomprises a buffer circuit and a processing circuit. The buffer circuitis configured for receiving and buffering a data unit transmitted fromthe host device and to be stored into the memory device. The processingcircuit is coupled to the buffer circuit and configured for using an SLCstoring mode to store the data unit, transmitted from the host device,into the memory device for one time, a size of the data unit being notlarger than a size of a storage page unit of the memory device.

According to the embodiments, a memory controller coupled between amemory device and a host device is disclosed. The memory device supportsat least three different storing modes. The memory controller comprisesa buffer circuit and a processing circuit. The buffer circuit isconfigured for receiving and buffering a data unit transmitted from thehost device and to be stored into the memory device. The processingcircuit is coupled to the buffer circuit and is configured for using anMLC storing mode to store the data unit, transmitted from the hostdevice, into the memory device for one time, a size of the data unitbeing not larger than a size of two storage page units of the memorydevice.

According to the embodiments, a method applied into a memory controllercoupled between a memory device and a host device is disclosed. Thememory device supports at least two different storing modes. The methodcomprises: receiving and buffering data transmitted from the hostdevice; using a first storing mode to store a first data unit into thememory device, a size of the first data unit being not larger than asize of a specific storage unit defined in the memory device; and usinga second storing mode, different from the first storing mode, to store asecond data unit into the memory device, a size of the second data unitbeing larger than the size of the specific storage unit.

According to the embodiments, the performance of storing data into thememory device can be improved significantly as well as the circuit costscan be reduced.

These and other objectives of the present invention will no doubt becomeobvious to those of ordinary skill in the art after reading thefollowing detailed description of the preferred embodiment that isillustrated in the various figures and drawings.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a flowchart diagram of a method applied into a memorycontroller (e.g. a flash memory controller) to dynamically switch from astoring mode into a different storing mode to use different storingmodes to store different sizes of data into a memory device such as aflash memory device respectively according to embodiments of theinvention.

FIG. 2 is a block diagram of a memory controller according to oneembodiment of FIG. 1.

FIG. 3 is a diagram showing an example of memory controller as shown inFIG. 2 storing data into the memory device by dynamically using the SLCand MLC data storing modes.

FIG. 4 is a diagram of an example of the communication between memorycontroller and memory device by dynamically using SLC data storing modeand MLC data storing mode to store data into the memory device.

DETAILED DESCRIPTION

Refer to FIG. 1 in conjunction with FIG. 2. FIG. 1 is a flowchartdiagram of a method applied into a memory controller (e.g. a flashmemory controller) to dynamically switch from a storing mode into adifferent storing mode to use different storing modes to store differentsizes of data into a memory device such as a flash memory devicerespectively according to embodiments of the invention. FIG. 2 is ablock diagram of a memory controller 200 according to one embodiment ofFIG. 1. The memory controller 200 for example is a part of a storagedevice 203 (e.g. solid state drive/disk (SSD)) which also comprises thememory device 202 such as 3D flash memory, and is coupled between thehost device/terminal 201 and the memory device 202, and comprises abuffer circuit 205 and a processing circuit 210.

Provided that substantially the same result is achieved, the steps ofthe flowchart shown in FIG. 1 need not be in the exact order shown andneed not be contiguous, that is, other steps can be intermediate. Stepsare detailed in the following:

Step 105: Use the buffer circuit 205 to receive and buffer a data unittransmitted from the host device 201;

Step 110: Use the processing circuit 210 to determine whether a size ofthe data unit is not larger than a size of a particular/specific storageunit defined in the memory device 202; if the size of the data unit isnot larger than the size of the particular/specific storage unit, theflow proceeds to Step 115A, otherwise, the flow proceeds to Step 115B;

Step 115A: Use a first storing mode to store the data unit into thememory device 202;

Step 115B: Use a second storing mode, different from the first storingmode, to store the data unit into the memory device 202; and

Step 120: End.

As shown in FIG. 2, the buffer circuit 205 is arranged to receive andbuffer data transmitted from the host device 201 (Step 105). Forexample, the host device 201 may be a camera device or a drivingrecorder (but not limited), and may sequentially write/record differentdata having identical or almost identical data size such as 4 KB data(but not limited) into the memory device 202 of the storage device 203.Each time when the host device 201 transmits a data unit to the memorycontroller 200, the memory controller 200 is use the buffer circuit 205to receive and buffer such data unit and initiates one data storingoperation for one time to write or store the data unit into the flashmemory 202.

The memory device 202 is for example a 3D flash memory device and iscapable of supporting at least two different storing modes such as SLC(single-level-cell) storing/programming mode and MLC (multi-level-cell)storing/programming mode. In other embodiments, the memory device 202may further support TLC (triple-level-cell) storing/programming modeand/or QLC (quad-level-cell) storing/programming mode. In the SLCstoring mode, the memory controller 200 is arranged to execute the datastoring operation for one time to store/program data of one storage page(size) into a single storage page unit of memory device 202. That is,one storage page is stored. In the MLC storing mode, the memorycontroller 200 is arranged to execute the data storing operation for onetime to store/program data of two storage pages into two storage pageunits (even page and odd page) of memory device 202. That is, twostorage pages (even page and odd page) are stored. For example, thefirst storing mode mentioned above is the SLC storing mode, and thesecond storing mode mentioned above is the MLC storing mode. That is,the memory controller 200 may use the SLC storing mode to store onestorage page data into a storage page of the memory device 202 or usethe MLC storing mode to store two storage page data into two storagepages of the memory device 202. The minimum data amount which isactually stored into the memory device 202 is equal to one storage pagewhen performing the storing operation for one time.

The data to be recorded each time may be larger or not larger than asize of one storage page unit in the memory device 202. In an example,the size of one storage page unit in the memory device 202 may be equalto 16K bytes (or 32K bytes), and the data to be recorded and stored eachtime may be equal to 4K bytes (but not limited). To save memory circuitcosts, the buffer circuit 205 can be implemented using a smaller memorycapacity (e.g. 4K bytes or 8K bytes, smaller than 16K bytes or 32Kbytes), and the memory controller 200 is arranged to read back someportion data from memory device 202, use the 4K bytes with the readportion data to form and generate one storage page data, and store theone storage page data into a storage page unit of memory device 202.This will be described again.

In Step 110, the processing circuit 210 is arranged to determine whetherthe size of data unit transmitted from host device 201 is not largerthan that of a particular storage unit or not. In this embodiment, thesize of a particular storage unit means the size of a single storagepage. For example, when the size of data unit is larger than that of onestorage page, the processing circuit 210 is arranged to activate and usethe MLC storing mode to store such data unit into two storage pages(even page and odd page) of the memory device 202 (Step 115B). Inpractice, the processing circuit 210 is arranged to activate a datacomplement process (a header data complement process and/or a tail datacomplement process) to read back portion data from the memory device 202and use the portion data with the data unit to form/generate two pagedata (i.e. data (data amount) of two storage pages) and then use the MLCstoring mode to store the two page data into two storage pages of thememory device 202.

Alternatively, when the size of data unit is equal to or smaller thanthat of one storage page, the processing circuit 210 is arranged toactivate and use the SLC storing mode to store such data unit into astorage page of the memory device 202 (Step 115A). In practice, theprocessing circuit 210 is arranged to activate the data complementprocess (a header data complement process and/or a tail data complementprocess) to read back portion data from the memory device 202 and usethe portion data with the data unit to form/generate one page data (i.e.data (data amount) of one storage page) and then use the SLC storingmode to store the one page data into one storage page of the memorydevice 202. The processing circuit 210 is able to dynamically usedifferent storing modes to store data of different sizes into the memorydevice 202. Compared to the conventional mechanism, the performance ofmemory controller 200 is not degraded as well as the circuit costs canbe saved significantly.

FIG. 3 is a diagram showing an example of memory controller 200 as shownin FIG. 2 storing data into the memory device 202 by dynamically usingthe SLC and MLC storing modes. In this example, the memory device 202defines even pages and odd pages. The host device 201 may sequentiallywrite or record/update data units each having 4K bytes data amount tothe storage device 203, and the size of one storage page unit in thememory device 202 is equal to 16K bytes. As shown in FIG. 3, the hostdevice 201 may write a data unit having 4K bytes, e.g. D1, to the memorycontroller 200, and then the buffer circuit 205 receives and bufferssuch data unit D1. The processing circuit 210 is then used for activatethe data complement process to read back portion data from the memorydevice 202 wherein the size of portion data is equal to that of threedata units F2, F3, F4, each having 4K bytes, i.e. 12K bytes. Forexample, the data unit D1 may mean that the processing circuit 210 isarranged to store the data unit Dl into the location of the first 4Kbytes of an even storage page in the memory device 202, and theprocessing circuit 210 is arranged to read back the second, third, andfourth 4K bytes, i.e. F2, F3, and F4 of such even storage page. Theprocessing circuit 210 uses the data unit D1 with the 12K bytes (dataF2, F3, F4) to form/generate one page data (16K bytes) and use the SLCstoring mode to store the one page data into a storage page unit (thesame page or different page) of the memory device 202. The processingcircuit 210 does not read back data from an odd storage pagecorresponding to the even storage page. The processing circuit 210processes only one page data amount without processing two page dataamount.

In addition, the processing circuit 210 may be arranged to store dataunit D3, which is to be stored into the location of the third 4K bytesof the even storage page. The processing circuit 210 is arranged to readback the first, second, and fourth 4K bytes, e.g. D1, F2, and F4 of sucheven storage page. The processing circuit 210 uses the data unit D3 withthe 12K bytes (data D1, F2, F4) to form/generate one page data (16Kbytes) and use the SLC storing mode to store the one page data into astorage page unit (the same page or different page) of the memory device202. The processing circuit 210 does not read back data from an oddstorage page corresponding to the even storage page. The processingcircuit 210 processes only one page data amount without processing twopage data amount.

In addition, the processing circuit 210 may be arranged to store dataunit D6, which is to be stored into the location of the second 4K bytesof an odd storage page. The processing circuit 210 is arranged to readback the first, third, and fourth 4K bytes, e.g. F5, F7, and F8 of suchodd storage page. The processing circuit 210 uses the data unit D6 withthe 12K bytes (data F5, F7, F8) to form/generate one page data (16Kbytes) and use the SLC storing mode to store the one page data into astorage page unit (the same page or different page) of the memory device202. The processing circuit 210 does not read back data from an evenstorage page corresponding to the odd storage page. The processingcircuit 210 processes only one page data amount without processing twopage data amount.

In addition, the processing circuit 210 may be arranged to store dataunit D8, which is to be stored into the location of the fourth 4K bytesof the odd storage page. The processing circuit 210 is arranged to readback the first, second, third 4K bytes, e.g. F5, D6, and F7 of such oddstorage page. The processing circuit 210 uses the data unit D8 with the12K bytes (data F5, D6, F7) to form/generate one page data (16K bytes)and use the SLC storing mode to store the one page data into a storagepage unit (the same page or different page) of the memory device 202.The processing circuit 210 does not read back data from an even storagepage corresponding to the odd storage page. The processing circuit 210processes only one page data amount without processing two page dataamount.

FIG. 4 is a diagram of an example of the communication between memorycontroller 200 and memory device 202 by dynamically using SLC storingmode and MLC storing mode to store data into the memory device 202. Asshown in FIG. 4, in a default setting (but not limited), the memorycontroller 200 is arranged to store data into the memory device 202using MLC storing mode. In the MLC storing mode for storing even and oddstorage pages, the processing circuit 210 issues or sends a writecommand WRITE, an even storage page address ADDR1, even storage pagedata EP such as 16K bytes data, and an end command END to the memorydevice 202 so as to store the even storage page data EP into an evenstorage page of memory device 202. The processing circuit 210 thenissues or sends the write command WRITE, an odd storage page addressADDR2, odd storage page data OP such as 16K bytes data, and the endcommand END to the memory device 202 so as to store the odd storage pagedata OP into an odd storage page of memory device 202. For example, thewrite command WRITE may be 80h command and the end command END may be10h command for a memory device produced or manufactured by the companyof Micron Technology Inc. Additionally, the write command WRITE may be80h command and the end command END may be 22h command for a memorydevice produced or manufactured by the company of SK Hynix Inc.

When determining that the data size of a buffered data unit is notlarger than that of one storage page data, the memory controller 200 canswitch to the SLC storing mode. In the SLC storing mode for storing asingle storage page, the processing circuit 210 is arranged for furtherissuing or sending a particular command C1 which is followed by theabove-mentioned write command WRITE before sending the write commandWRITE. When the memory device 202 receives the particular command C1 andthe write command WRITE, the memory device 202 can know that the memorycontroller 200 is arranged to store a single storage page. For example,the particular command C1 may be DAh command for the company of MicronTechnology Inc., and may be BEh command for the company of SK Hynix Inc.In practice, in the SLC storing mode for storing an even or odd storagepage, the processing circuit 210 issues or sends the particular commandC1 (DAh command or BEh command), the write command WRITE (80h command),an even/odd storage page address ADDR, even/odd storage page data DATAsuch as 16K bytes data, and the end command END (10h command or 22hcommand) to the memory device 202 so as to store the even or odd storagepage data DATA into an even or odd storage page of memory device 202.

Further, in other embodiments, the method of FIG. 1 can be applied intothe memory device 202 supporting at least three different storing modessuch as SLC, MLC, and TLC (triple-level-cell) storing modes. The firststoring mode can be the SLC storing mode or MLC storing mode, and thesecond storing mode can be the TLC storing mode. In the default setting,the memory controller 200 can be arranged to use the TLC storing mode towrite or store data units, transmitted from the host device 201, intothe memory device 202. When determining that the size of a data unit isnot larger than the size of two storage page data, the processingcircuit 210 can switch from the TLC storing mode to the MLC storing modeand employ the MLC storing mode to store the data unit into the memorydevice. In addition, if determining that the size of such data unit isnot larger than the size of one storage page data, the processingcircuit 210 can switch from the TLC storing mode to the SLC storing modeand employ the SLC storing mode to store the data unit into the memorydevice.

Similarly, the method can be also applied into the memory device 202supporting at least four different storing modes such as SLC, MLC, TLC,and QLC (quad-level-cell) storing modes. The operation is similar to theabove-mentioned operation and the corresponding description is notdetailed for brevity.

To summarize, the method and memory controller 200 are capable ofswitching between at least two different storing modes such as first andsecond storing modes and using the different storing modes torespectively store data units having different sizes into the memorydevice 202 wherein the first storing mode corresponds to M-level celldata storing and the second storing mode corresponds to N-level celldata storing. M and N are positive integers and M is smaller than N.

Those skilled in the art will readily observe that numerousmodifications and alterations of the device and method may be made whileretaining the teachings of the invention. Accordingly, the abovedisclosure should be construed as limited only by the metes and boundsof the appended claims.

What is claimed is:
 1. A memory controller coupled between a memorydevice and a host device, the memory device supporting at least twodifferent storing modes, and the memory controller comprising: a buffercircuit, configured for receiving and buffering data transmitted fromthe host device; and a processing circuit, coupled to the buffercircuit, configured for: using a first storing mode to store a firstdata unit into the memory device, a size of the first data unit beingnot larger than a size of a specific storage unit defined in the memorydevice; and using a second storing mode, different from the firststoring mode, to store a second data unit into the memory device, a sizeof the second data unit being larger than the size of the specificstorage unit.
 2. The memory controller of claim 1, wherein the specificstorage unit is equal to one storage page; the first storing mode is anSLC (single-level-cell) storing mode, and the second storing mode is anMLC (multi-level-cell) storing mode.
 3. The memory controller of claim1, wherein the specific storage unit is equal to two storage pages; thefirst storing mode is an MLC storing mode, and the second storing modeis an TLC (triple-level-cell) storing mode.
 4. The memory controller ofclaim 2, wherein the processing circuit is arranged for determiningwhether the size of the data unit is larger than the size of thespecific storage unit.
 5. The memory controller of claim 2, wherein theprocessing circuit is arranged to read back a portion data from thememory device and use the portion data and the first data unit toform/generate a storage page data, and then is arranged to store thestorage page data into a single storage page by using the SLC storingmode.
 6. The memory controller of claim 5, wherein the processingcircuit is arranged to read back another portion data from the memorydevice and use the another portion data and the second data unit toform/generate two storage page data, and then is arranged to store thetwo storage page data into two storage pages by using the MLC storingmode.
 7. The memory controller of claim 2, wherein the processingcircuit is arranged to send an SLC storing command to the memory deviceto use the SLC storing mode to store the first data unit into the memorydevice, and is arranged to send an MLC storing command to the memorydevice to use the MLC storing mode to store the second data unit intothe memory device.
 8. The memory controller of claim 1, wherein thefirst storing mode corresponds to M-level cell data storing, and thesecond storing mode corresponds to N-level cell data storing; M and Nare positive integers and M is smaller than N.
 9. A memory controllercoupled between a memory device and a host device, the memory devicehaving at least two different storing modes, and the memory controllercomprising: a buffer circuit, configured for receiving and buffering adata unit transmitted from the host device and to be stored into thememory device; and a processing circuit, coupled to the buffer circuit,configured for using an SLC storing mode to store the data unit,transmitted from the host device, into the memory device for one time, asize of the data unit being not larger than a size of a storage pageunit of the memory device.
 10. The memory controller of claim 9, whereinthe processing circuit is arranged for reading back a portion data fromthe memory device, forming a storage page data by using the portion dataand the data unit, and then storing the storage page data into a singlestorage page unit of the memory device.
 11. A memory controller coupledbetween a memory device and a host device, the memory device having atleast three different storing modes, and the memory controllercomprising: a buffer circuit, configured for receiving and buffering adata unit transmitted from the host device and to be stored into thememory device; and a processing circuit, coupled to the buffer circuit,configured for using an MLC storing mode to store the data unit,transmitted from the host device, into the memory device for one time, asize of the data unit being not larger than a size of two storage pageunits of the memory device.
 12. A method applied into a memorycontroller coupled between a memory device and a host device, the memorydevice supporting at least two different storing modes, and the methodcomprises: receiving and buffering data transmitted from the hostdevice; using a first storing mode to store a first data unit into thememory device, a size of the first data unit being not larger than asize of a specific storage unit defined in the memory device; and usinga second storing mode, different from the first storing mode, to store asecond data unit into the memory device, a size of the second data unitbeing larger than the size of the specific storage unit.
 13. The methodof claim 12, wherein the specific storage unit is equal to one storagepage; the first storing mode is an SLC (single-level-cell) storing mode,and the second storing mode is an MLC (multi-level-cell) storing mode.14. The method of claim 12, wherein the specific storage unit is equalto two storage pages; the first storing mode is an MLC storing mode, andthe second storing mode is an TLC (triple-level-cell) storing mode. 15.The method of claim 13, further comprising: determining whether the sizeof the data unit is larger than the size of the specific storage unit.16. The method of claim 13, wherein the step of using the first storingmode to store the first data unit into the memory device comprises:reading back a portion data from the memory device; using the portiondata and the first data unit to form/generate a storage page data; andstoring the storage page data into a single storage page by using theSLC storing mode.
 17. The method of claim 16, wherein the step of usingthe second storing mode to store the second data unit into the memorydevice comprises: reading back another portion data from the memorydevice; using the another portion data and the second data unit toform/generate two storage page data; and storing the two storage pagedata into two storage pages by using the MLC storing mode.
 18. Themethod of claim 13, further comprising: sending an SLC storing commandto the memory device to use the SLC storing mode to store the first dataunit into the memory device; and sending an MLC storing command to thememory device to use the MLC storing mode to store the second data unitinto the memory device.
 19. The method of claim 12, wherein the firststoring mode corresponds to M-level cell data storing, and the secondstoring mode corresponds to N-level cell data storing; M and N arepositive integers and M is smaller than N.